<?php
App::uses('AppModel', 'Model');
/**
 * KursyType Model
 *
 * @property Kursy $Kursy
 */
class GalleryCategory extends AppModel {
/**
 * Display field
 *
 * @var string
 */
	public $displayField = 'name';
/**
 * Validation rules
 *
 * @var array
 */
	public $validate = array(
		'name' => array(
			'notempty' => array(
				'rule' => array('notempty'),
				//'message' => 'Your custom message here',
				//'allowEmpty' => false,
				//'required' => false,
				//'last' => false, // Stop validation after this rule
				//'on' => 'create', // Limit validation to 'create' or 'update' operations
			),
		),
	);

	//The Associations below have been created with all possible keys, those that are not needed can be removed

/**
 * hasAndBelongsToMany associations
 *
 * @var array
 */
	public $hasAndBelongsToMany = array(
// 		'Kursy' => array(
// 			'className' => 'Kursy',
// 			'joinTable' => 'kursy_kursy_types',
// 			'foreignKey' => 'kursy_type_id',
// 			'associationForeignKey' => 'kursy_id',
// 			'unique' => 'keepExisting',
// 			'conditions' => '',
// 			'fields' => '',
// 			'order' => '',
// 			'limit' => '',
// 			'offset' => '',
// 			'finderQuery' => '',
// 			'deleteQuery' => '',
// 			'insertQuery' => ''
// 		),
	'Gallery' => array(
				'className' => 'Gallery',
				'joinTable' => 'galleries_gallery_categories',
				'foreignKey' => 'gallery_category_id',
				'associationForeignKey' => 'gallery_id',
				'unique' => 'keepExisting',
				'conditions' => '',
				'fields' => '',
				'order' => '',
				'limit' => '',
				'offset' => '',
				'finderQuery' => '',
				'deleteQuery' => '',
				'insertQuery' => ''
	)
	);

}
